/**  
 * All rights Reserved, Designed By <a href="www.itttq.com" target="_blank">www.itttq.com</a>
 * @date:   2017-07-21 11:42:21
 * @Copyright: 2017 <a href="www.itttq.com" target="_blank">www.itttq.com</a> Inc. All rights reserved. 
 */
package com.itttq.gshop.pbpm.mapper;

import java.util.List;

import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.DeleteProvider;
import org.apache.ibatis.annotations.InsertProvider;
import org.apache.ibatis.annotations.Lang;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.SelectProvider;
import org.apache.ibatis.annotations.UpdateProvider;

import com.itttq.gshop.domain.po.PayMethodPo;
import com.itttq.gshop.pbpm.cmpt.mybatis.CustomInLanguage;
import com.itttq.gshop.pbpm.provider.PayMethodSqlProvider;

@Mapper
public interface IPayMethodMapper {
	/**
	 * 新增PayMethodPo对象
	 * 
	 * @param PayMethodPo
	 * @Author 迷蝶
	 * @return Integer
	 */
	@InsertProvider(type=PayMethodSqlProvider.class,  method="addPayMethod") 
	public Integer addPayMethod(PayMethodPo payMethod);

	/**
	 * 更新PayMethodPo对象
	 * 
	 * @param payMethodPo
	 * @Author 迷蝶
	 * @return Integer
	 */
	@UpdateProvider(type=PayMethodSqlProvider.class,  method="updatePayMethod") 
	public Integer updatePayMethod(PayMethodPo payMethod);
	
	/**
	 * 根据ID删除PayMethodPo对象
	 * 
	 * @param id
	 * @Author 迷蝶
	 * @return Integer
	 */
	@DeleteProvider(type=PayMethodSqlProvider.class,  method="delPayMethod") 
	public Integer delPayMethodById(Integer id);

	/**
	 * 根据IDS删除PayMethodPo对象
	 * 
	 * @param ids
	 * @Author 迷蝶
	 * @return List<PayMethodPo>
	 */
	@Lang(CustomInLanguage.class)
	@Delete("DELETE FROM pay_method WHERE id IN (#{ids})")
	public Integer delPayMethodByIds(@Param("ids") List<Integer> ids);
	
	/**
	 * 根据条件查找PayMethodPo对象，默认根据ID降序
	 * 
	 * @param payMethodPo
	 * @Author 迷蝶
	 * @return List<PayMethodPo>
	 */
	@SelectProvider(type=PayMethodSqlProvider.class,  method="findPayMethods") 
	public List<PayMethodPo> findPayMethods(PayMethodPo payMethod);
	
	/**
	 * 根据条件查找记录总数
	 * 
	 * @param payMethodPo
	 * @Author 迷蝶
	 * @return Integer
	 */
	@SelectProvider(type=PayMethodSqlProvider.class,  method="findPayMethodCount") 
	public Integer findPayMethodCount(PayMethodPo payMethod);

	/**
	 * 根据ID查找PayMethodPo对象
	 * 
	 * @param id
	 * @Author 迷蝶
	 * @return PayMethodPo
	 */
	@SelectProvider(type=PayMethodSqlProvider.class,  method="findPayMethodById") 
	public PayMethodPo findPayMethodById(Integer id);
	
}